from sqlalchemy import Column, Integer, String, Boolean

from db.config import Base


class Role(Base):
    __tablename__ = "role"

    id = Column(Integer, primary_key=True, index=True, autoincrement=True)
    code = Column(String(50), unique=True, nullable=False, index=True)
    name = Column(String(50), nullable=False, index=True)
    enable = Column(Boolean, default=True, nullable=False)
